package com.example.demo.service.serviceimpl;

import com.example.demo.dao.BannersDao;
import com.example.demo.entity.BannersEntity;
import com.example.demo.service.BannersService;
import com.example.demo.vo.BannersVo;
import jakarta.annotation.Resource;
import org.springframework.stereotype.Service;

import java.util.List;
@Service
public class BannersServiceImpl implements BannersService {
    @Resource
    BannersDao bannersDao;
    @Override
    public List<BannersEntity> getBanners() {
        return bannersDao.getBanners() ;
    }

    @Override
    public int addBanners(BannersVo bannersVo) {
        return bannersDao.addBanners(bannersVo) ;
    }

    @Override
    public int updateBanners(BannersVo bannersVo) {
        return  bannersDao.upBanners(bannersVo) ;
    }

    @Override
    public int deleteBanners(int id) {
        return bannersDao.delBanners(id) ;
    }
}
